#ifndef _DW1000_H_
#define _DW1000_H_

#include "stm32f1xx_hal.h"
#include "main.h"

#define DW1000_CS_PORT			UWB_CSN_GPIO_Port
#define DW1000_CS_PIN				UWB_CSN_Pin
#define DW1000_RST_PORT			UWB_RSTn_GPIO_Port
#define DW1000_RST_PIN			UWB_RSTn_Pin
#define DW1000_WAKEUP_PORT	    UWB_Wakeup_GPIO_Port
#define DW10000_WAKEUP_PIN	    UWB_Wakeup_Pin

#define DW1000_IRQn_TYPE		UWB_IRQ_EXTI_IRQn
#define DW1000_IRQ_PORT		  UWB_IRQ_GPIO_Port
#define DW1000_IRQ_PIN			UWB_IRQ_Pin


extern SPI_HandleTypeDef hspi1;
#define DW1000_SPI_Handle hspi1

void reset_DW1000(void);
void spi_set_rate_low(void);
void spi_set_rate_high(void);

#endif /* _DW1000_H_ */
